<template>
  <!-- 认证标签 -->
  <template v-if="certificationType">
    <RoleTag
      v-if="certificationType === AuthTypeEnum.PERSONAL"
      text="个人认证"
      icon="icon-yonghuqun"
      type="member"
    />
    <RoleTag
      v-if="certificationType === AuthTypeEnum.ENTERPRISE"
      text="企业认证"
      icon="icon-danwei_fill"
      type="member"
    />
    <RoleTag
      v-if="certificationType === AuthTypeEnum.ORGANIZATION"
      text="组织认证"
      icon="icon-yonghu"
      type="member"
    />
  </template>
  <RoleTag v-else text="未认证" type="guest" />
</template>

<script setup lang="ts">
  import { AuthTypeEnum } from '@/enums/LoginEnum';
  import RoleTag from './index.vue';

  defineOptions({
    name: 'AuthenticationTag',
  });

  defineProps<{
    certificationType?: AuthTypeEnum | null;
  }>();
</script>

<style scoped></style>
